package com.jzo2o.customer.controller.open;

import com.github.xiaoymin.knife4j.annotations.ApiSort;
import com.jzo2o.common.model.Result;
import com.jzo2o.customer.model.dto.request.InstitutionRegisterReqDTO;
import com.jzo2o.customer.service.IInstitutionStaffService;
import com.jzo2o.customer.service.IServeProviderService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController("openRegisterController")
@RequestMapping("/open/serve-provider")
@Api(tags = "机构注册相关接口")
public class RegisterController {
    @Autowired
    private IServeProviderService serveProviderService;

    /**
     * 注册机构
     * @param reqDTO
     * @return
     */
    @PostMapping("/institution/register")
    @ApiOperation("机构注册接口")
    public Result register(@RequestBody InstitutionRegisterReqDTO reqDTO){
        serveProviderService.register(reqDTO);
        return Result.ok();
    }
}
